package data;

import java.io.File;
import java.io.IOException;


public class StockMain {

	public static void main(String[] args) {
//		SaveHistoryData shd = new SaveHistoryData();
//		try {
//			File file = new File("historydata"+File.separator+"last.sto");
//			if(file.exists()){
//				LoadData.loadAllData();
//			}else{
//				shd.saveHistoryData();
//			}
//		} catch (IOException e) {
//			e.printStackTrace();
//		}
		try {
			System.out.println(StockDataFetch.getstockData("http://hq.sinajs.cn/list=sz300215,sz000858,sz300133"));
			String codeData = StockDataFetch.getstockData("http://hq.sinajs.cn/list=sz300215,sz000858,sz300133");
			String codeTemp = codeData.substring(11,codeData.indexOf("="));
			System.out.println(codeTemp);
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}
